<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
	request.setAttribute("path", basePath);
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>二级页面</title>
<script type="text/javascript">
   function addCategory(result){
	   alert(result);
	   window.open("<%=path %>/manager/category/categoryAdd.jsp?parentId="+result,"categoryContent","channelmode=yes");
   }
</script>
</head>
<body>

	<input type="button" value="新增类别"	onclick="addCategory(${parentId})" />

<br><br />
	<table border="1px" cellspacing="0px">
		<tr>
			<th>本类别Id</th>
			<th>类别名称</th>
			<th>上一级属性Id</th>
			<th>创建时间</th>
		</tr>

		<c:forEach items="${requestScope.queryGoodsTypeByParentId}"
			var="goodsType">

			<tr>
				<td>${goodsType.id}</td>
				<td>${goodsType.typeName}</td>
				<td>${goodsType.parentId}</td>
				<th>${goodsType.createTime}</th>
			</tr>

		</c:forEach>


	</table>
</body>
</html>